#ifndef ABOS_KERN_PROC_H
#define ABOS_KERN_PROC_H

#include <include/proc.h>

extern struct Proc *procs;		// All processes.
extern struct Proc *curproc;	    // Current process.

void	proc_init(void);
void	proc_create(uint8_t *p);
int		proc_alloc(struct Proc **new_proc, pid_t parent_id);

// The following two functions do not return
void	proc_run(struct Proc *p) __attribute__((noreturn));
void	proc_pop_tf(struct Trapframe *tf) __attribute__((noreturn));

#endif // !ABOS_KERN_PROC_H
